import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementUI from 'element-ui';
import request from './utils/request';
import 'element-ui/lib/theme-chalk/index.css';
import '../src/assets/styles/common.less';
// 导入插件
import UI from '@/components/library'
// 表单vee-validate配置
import { ValidationProvider, ValidationObserver, extend } from 'vee-validate';
import * as rules from 'vee-validate/dist/rules';

// 注册所有规则
Object.keys(rules).forEach(rule => {
  extend(rule, rules[rule]);
});

// 注册全局组件
Vue.component('ValidationProvider', ValidationProvider);
Vue.component('ValidationObserver', ValidationObserver);

Vue.config.productionTip = false
Vue.use(ElementUI);
Vue.use(UI);
Vue.prototype.request=request;


new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
